package cn.rongdao.jrkabao.ui.deposit.adapter;

import android.content.Context;
import android.view.ViewGroup;

import com.mifengkong.frtools.ui.adapter.recyclerview.FRBaseRecyclerAdapter;
import com.mifengkong.frtools.inputmethod.FRView;

import cn.rongdao.jrkabao.R;
import cn.rongdao.jrkabao.bean.deposit.SelectMonthBean;

/**
 * Created by jack on 2017/7/31
 */

public class SelectMonthAdapter extends FRBaseRecyclerAdapter<SelectMonthBean, SelectMonthViewHolder> {

    public SelectMonthAdapter(Context context, OnItemClickListener<SelectMonthViewHolder> listener) {
        super(context, listener);
    }

    @Override
    public SelectMonthViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
        return new SelectMonthViewHolder(FRView.inflateLayout(getContext(), R.layout.item_select_month, parent, false));
    }

    public void setAllUnSelect() {
        for (SelectMonthBean data : getDataList()) {
            data.setSelected(false);
        }
    }
}
